<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>POPUP.JS</title>
<script type="text/javascript" src="popup.js"></script>
     <script type="text/javascript">
    
         function ShowIframe()
         {
             var pop=new Popup({ contentType:1,isReloadOnClose:false,width:400,height:500});
             pop.setContent("contentUrl","Login.htm");
             pop.setContent("title","iframe框架示例");
             pop.build();
             pop.show();
         }
         function ShowHtmlString()
    {
             var strHtml = "<table border=1 style='width:90%; text-align:center;'><tr style='height:40px'><td>ds</td><td>dads</td></tr><tr style='height:40px'><td>dadas</td><td>dasd</td></tr><tr style='height:40px'><td>dadasd</td><td>dsadads</td></tr></table>";
             var pop=new Popup({ contentType:2,isReloadOnClose:false,width:340,height:300});
             pop.setContent("contentHtml",strHtml);
             pop.setContent("title","html字符串示例");
             pop.build();
             pop.show();
         }
         function ShowConfirm()
      {
             var pop=new Popup({ contentType:3,isReloadOnClose:false,width:340,height:80});
             pop.setContent("title","confirm对话框示例");
             pop.setContent("confirmCon","confirm对话框的内容");
             pop.setContent("callBack",ShowCallBack);
             pop.setContent("parameter",{id:"divCall",str:"点击确定后显示的字符串",obj:pop});
             pop.build();
             pop.show();
         }
         function ShowAlert()
         {
             var pop=new Popup({ contentType:4,isReloadOnClose:false,width:340,height:80});
             pop.setContent("title","alert警告框示例");
             pop.setContent("alertCon","alert对话框的内容");
             pop.build();
             pop.show();
         }
        function ShowCallBack(para)
         {
             var o_pop = para["obj"]
             var obj = document.getElementById(para["id"]);
             o_pop.close();
             obj.innerText = para["str"];
            
         }
</script>

<div>
     <a href="javascript:ShowIframe()">iframe框架示例</a>
     <br />
     <a href="javascript:ShowHtmlString()">html字符串示例</a>
     <br />
     <a href="javascript:ShowConfirm()">confirm对话框示例</a>
     <br />
     <a href="javascript:ShowAlert()">alert警告框示例</a>
 </div>


